package com.huashi.dealer.modular.business.order.param;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.util.Map;

/**
 * 订单审核参数
 *
 * @author 谭陈强
 * @since 2025-08-15
 */
@Data
@Schema(description = "订单审核参数")
public class OrderAuditParam {

    @Schema(description = "订单ID", example = "1001", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "订单ID不能为空")
    private Long orderId;

    @Schema(description = "审核结果：20-通过，40-驳回", example = "20", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "审核结果不能为空")
    private Integer auditStatus;

    @Schema(description = "审核备注", example = "审核通过")
    private String auditRemark;

    @Schema(description = "驳回原因（驳回时必填）", example = "商品库存不足")
    private String rejectReason;

    @Schema(description = "审核人ID", example = "1001")
    private Long auditorId;

    @Schema(description = "审核人姓名", example = "张三")
    private String auditorName;
    
    // ========== 商品数量修改相关字段（对应PHP版本的goods_num和goods_id） ==========
    
    @Schema(description = "商品ID列表（用于数量修改）")
    private Long[] goodsIds;
    
    @Schema(description = "商品数量映射（key: 商品ID, value: 修改后的数量）")
    private Map<Long, Integer> goodsNum;
}
